<#assign pageName="新增任务信息">
<@override name="page-content">
    <fieldset class="layui-elem-field layui-field-title">
        <legend>${pageName}</legend>
    </fieldset>
    <form class="layui-form padding-10" lay-filter="formJobAdd">
        <@ctrl.SingleSelect path="quartzJob.jobGroup" options={"0":"默认", "1":"系统"} 
            text="1" value="0" labelText="任务分组" required="required"/>
        <@ctrl.Textbox path="quartzJob.jobName" labelText="任务名称" required="required"/>
        <div class="layui-form-item">
            <label class="layui-form-label" for="cronExpression">
                <b style="color:red;padding:2px;vertical-align: middle;">*</b>Cron表达式
            </label>
            <div class="layui-input-block">
                <input type="text" id="cronExpression" autocomplete="off" placeholder="请输入Cron表达式" class="layui-input  " name="cronExpression" value="" lay-verify="required">
                <a href="https://cron.qqe2.com/" target="_blank">在线Cron表达式</a>
            </div>
       </div>
        <@ctrl.Textbox path="quartzJob.beanClass" labelText="任务执行类名" required="required"/>
        <@ctrl.Textarea path="quartzJob.jobDataMap" labelText="任务参数" />
        <@ctrl.Textarea path="quartzJob.remarks" labelText="任务描述" />
        <@ctrl.Textbox path="quartzJob.orderNo" labelText="排序编号" required="required"/>
        <@ctrl.FormAction backURL = "manage"/>
    </form>
</@override>
<@override name="page-scripts">
<script>
     $(function(){
         layui.use(['form','layer', 'jquery'], function(){
             var form = layui.form;
             var layer=layui.layer;
             $=layui.jquery;
             //监听提交
             form.on('submit(submit)', function(data){
                 submitData(data.field, '${contextPath}/quartz/job/add', function(){location.href="${contextPath}/quartz/job/manage";});
                 return false;
             });
         })
     })
</script>
</@override>
<@extends name="/layout/basepage.html"/> 